package com.spdd.mt.biz.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.spdd.mt.common.base.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 商品表
 * </p>
 *
 * @author shanfeilong
 * @since 2025-04-02
 */
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = false)
@TableName("mt_product")
public class MtProductEntity extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.AUTO)
    private Long id;

    /** 美团商户编码 */
    @TableField("merch_no")
    private String merchNo;

    /** 商品编码 */
    @TableField("product_code")
    private String productCode;

    /** 商品类型 ProductTypeEnum */
    @TableField("product_type")
    private Integer productType;

    /** 商品名称 */
    @TableField("product_name")
    private String productName;

    /** 运营商编码 CM CU CT */
    @TableField("operator")
    private String operator;

    /** 运营商名称 */
    @TableField("operator_name")
    private String operatorName;

    /** 面额 */
    @TableField("face_price")
    private Integer facePrice;

    /** 价格(分) */
    @TableField("price")
    private Long price;

    /** 省份编码 */
    @TableField("province_code")
    private String provinceCode;

    /** 省份名称 */
    @TableField("province_name")
    private String provinceName;

    /** 折扣 */
    @TableField("discount")
    private BigDecimal discount;

    /** 是否维护(1 未维护，2 已维护) */
    @TableField("maintenance_status")
    private Integer maintenanceStatus;

    /** 创建时间 */
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private Date createTime;

    /** 更新时间 */
    @TableField(value = "update_time", fill = FieldFill.UPDATE)
    private Date updateTime;

}
